//---------------------------------------------------------------------------------------------------------------------------------------------------------//
//---------------------------------------------------------------------------------------------------------------------------------------------------------//
#include <cstdlib>

#include <iostream>
#include <fstream>

#include "ManipulateMol2File.h"
//---------------------------------------------------------------------------------------------------------------------------------------------------------//
//---------------------------------------------------------------------------------------------------------------------------------------------------------//
using namespace std;
//---------------------------------------------------------------------------------------------------------------------------------------------------------//
//---------------------------------------------------------------------------------------------------------------------------------------------------------//
int main(int argc, char** argv) {

  String* locationPDB;
  String* locationMOL2;
  String* locationOut;

  if (argc < 4) {
    cout << "Error in the input arguments. The execution must be: " << endl;
    cout << "./ConvertMOL2ToPDBMetaStructure <Path of folder with PDB Files> <Path of folder with MOL2 Files> <Output Folder>" << endl;
    return 0;
  }
  else {
    cout << "---------------------------------------------------------------------------------" << endl;
    cout << " Folder with PDB Files : " << argv[1] << endl;
    cout << "Folder with MOL2 Files : " << argv[2] << endl;
    cout << "         Output Folder : " << argv[3] << endl;
    cout << "---------------------------------------------------------------------------------" << endl;
    locationPDB  = new String(argv[1]);
    locationMOL2 = new String(argv[2]);
    locationOut  = new String(argv[3]);
  }

  ManipulateMol2File* manipulateMol2File = new ManipulateMol2File();

  manipulateMol2File->LocationDBPDB(locationPDB);
  manipulateMol2File->LocationDBMOL2(locationMOL2);
  manipulateMol2File->LocationOut(locationOut);
  manipulateMol2File->ExtractExtendedPDBCoordinatesFromPDBFile();

  cout << "---------------------------------------------------------------------------------" << endl;

  if (manipulateMol2File) delete manipulateMol2File;

  return 1;

}
//---------------------------------------------------------------------------------------------------------------------------------------------------------//
//---------------------------------------------------------------------------------------------------------------------------------------------------------//


